﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="MyRecipe.aspx.cs" Inherits="CSC440TeamOne.MyNutrition.Views.MyRecipe" Title="MyRecipe" MasterPageFile="~/Shared/DefaultMaster.master" %>
<%@ Register Assembly="PlusMinusButton" Namespace="PlusMinus" TagPrefix="cc1" %>

<asp:Content ID="content" ContentPlaceHolderID="DefaultContent" Runat="Server">
	<h1>My Recipes</h1>
    <link href="../App_Themes/Default/MyRecipe.css" rel="stylesheet" type="text/css" />
    <div class="left">
        <div class="recSearch">
            <strong>Recipe Search:</strong> <asp:TextBox ID="txtSearch" runat="server" /><br />
            <div class="textLeft">-or-</div>
            <strong>Enter Ingredients:</strong> <asp:TextBox ID="txtIngredient" runat="server" /><br />
            <asp:Button ID="btnSearch" Text="Search" runat="server" onclick="btnSearch_Click" />
            <div class="textLeft">
                Results:<br />
                <asp:Repeater ID="repResults" runat="server" onitemcommand="repResults_ItemCommand" onitemdatabound="repResults_ItemDataBound">
                    <ItemTemplate>
                        <asp:LinkButton ID="LinkButton1" runat="server" CommandName="selectedRecipe" /><br />
                    </ItemTemplate>
                </asp:Repeater>
            </div>
        </div>
        <br />
        <div class="recDay">
            <strong>Recipe of the Day:</strong> <asp:LinkButton runat="server" id="rodName" onclick="rodName_Click"></asp:LinkButton>
            <asp:Image ID="Image2" style="float:right;" runat="server" />
        </div>
        <br />
        <div class="recFav">
            <strong>Favorite Recipes:</strong><br />
            <asp:Repeater ID="repFavorites" runat="server" onitemcommand="repFavorites_ItemCommand" onitemdatabound="repFavorites_ItemDataBound">
                <ItemTemplate>
                    <asp:LinkButton ID="LinkButton1" runat="server" CommandName="selectedRecipe" /><br />
                </ItemTemplate>
            </asp:Repeater>
        </div>
        <br />
        <div class="recSug">
            <strong>Suggested Recipes:</strong><br />
            <asp:Repeater ID="repSuggested" runat="server" onitemcommand="repSuggested_ItemCommand" onitemdatabound="repSuggested_ItemDataBound">
                <ItemTemplate>
                    <asp:LinkButton ID="LinkButton2" runat="server" CommandName="selectedRecipe" /><br />
                </ItemTemplate>
            </asp:Repeater>
        </div>
    </div>
    <div class="recipeViewer">
        <h2 runat="server" id="name"></h2>
        <asp:Image ID="Image1" style="float:right;" runat="server" />
        <asp:Repeater ID="repIngredients" runat="server" 
            onitemdatabound="repIngredients_ItemDataBound">
            <ItemTemplate>
                <asp:Label ID="Label1" runat="server" /><br />
            </ItemTemplate>
        </asp:Repeater>
        <asp:Label ID="lblDirections" runat="server" />
        <br /><br />
        <cc1:PlusMinusButton ID="PlusMinusButton1" runat="server" onclickminus="PlusMinusButton1_ClickMinus" onclickplus="PlusMinusButton1_ClickPlus"></cc1:PlusMinusButton>
        <br /><asp:HyperLink runat="server" ID="hypPrint">Print Recipe</asp:HyperLink>
    </div>
</asp:Content>